<#assign assign_EntityName = content.items.entity.className>
<#assign tableName = content.content.tableName>
package ${content.items.dao.packageName};
import org.apache.ibatis.annotations.Param;
import ibp.ioc.dao.core.BaseDAO;
import java.util.List;
import ${content.items.entity.packageName}.${assign_EntityName};

/**
 * ${tableName}表相关数据库操作
 * @author ist
 */
public interface ${content.items.dao.className} extends BaseDAO{
  //获取列表数据
  List<${assign_EntityName}> get${tableName?cap_first}List(${assign_EntityName} ${tableName});

  //获取详情数据
  ${assign_EntityName} get${tableName?cap_first}Disp(${assign_EntityName} ${tableName});

  //新增数据
  void insert${tableName?cap_first}(${assign_EntityName} ${tableName});

<#if content.content.primaryField??>
  //更新数据
  void update${tableName?cap_first}(${assign_EntityName} ${tableName});

  //通过ID获取数据
  <#assign assign_idFieldType = content.content.primaryField[0].fieldType>
  <#assign assign_idFieldName = content.content.primaryField[0].fieldName>
  ${assign_EntityName} get${tableName?cap_first}ById(@Param("${assign_idFieldName}")${assign_idFieldType} ${assign_idFieldName});

  //通过ID删除数据
  void delete${tableName?cap_first}ById(@Param("${assign_idFieldName}")${assign_idFieldType} ${assign_idFieldName});
</#if>

}
